package com.hello.controller;

import org.springframework.util.StringUtils;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

/**
 * @description:
 * @author: wangxf
 * @date: Created in 2021/9/19 18:07
 */
@RestController
public class HelloController {

    @GetMapping({"/", "/hello"})
    public String hello_docker(@RequestParam(name = "name", required = false, defaultValue = "") String name) {

        return StringUtils.hasLength(name) ? name : "Running with docker by idea plugins.";
    }

}
